home *** CD-ROM | disk | FTP | other *** search
/ BCI NET 2 / BCI NET 2.iso / archives / programming / amos / amoslist-0295.lzh / AMOSLIST / text0101.txt < prev    next >
Encoding:
Text File  |  1995-03-01  |  873 b   |  22 lines

  1. >    Hi there.
  2. >        Passing integers to assembly procedures is easy.But passing 
  3. >floating point numbers (eg A# etc) is somewhat complicated.We have to 
  4. >use Fast Floating Point format(FFP). This means :
  5. >MMMMMMMMMMMMMMMMMMMMMMMMSEEEEEEE where M is the 24bit mantissa, S is 
  6. >the sign and E is the exponent.Can anyone tell me how a number (let's 
  7. >say 32) is represented in this format? Is it 32 1E0?
  8.  
  9.   The exponent is biased by 65; in other words, you subtract 65 from the
  10. exponent field to get the actual exponent.  So 32 (1 * 2^5) would be:
  11.  
  12. 10000000 00000000 00000000 01000110
  13.  
  14. The mantissa is 1.000000... (there's an assumed binary point after the
  15. first digit), the sign bit is zero (positive), and the exponent is 5
  16. (70-65).
  17.  
  18.   --Andy Church (achurch@goober.mbhs.edu)
  19.     WWW: http://www.mbhs.edu/~achurch/
  20.     AMOS Web Site: http://www.mbhs.edu/~achurch/amos/
  21.  
  22.